#define _CRT_SECURE_NO_WARNINGS 1

#include"BTNode.h"

void test()
{
	char a[] = "ABD##E#H##CF##G##";
	size_t size = sizeof(a) / sizeof(a[0]);
	int i = 0;
	BTNode* root = BinaryTreeCreate(a, size, &i);

	BinaryTreePrevOrder(root);
	printf("\n");
	//printf("%d", BinaryTreeComplete(root));
	BinaryTreeInOrder(root);
	printf("\n");
	BinaryTreePostOrder(root);
	printf("\n");
	printf("%d\n", BinaryTreeLeafSize(root));
	printf("%d\n", BinaryTreeLevelKSize(root, 0));
	BTNode* pb = BinaryTreeFind(root, 'D');
	printf("%c\n", pb->_data);
	printf("%p\n ", NULL);
	BinaryTreeDestory(&root);
}

int main()
{
	test();
	return 0;
}